import wx
import requests
import json


class loading(wx.Frame):

    def __init__(self):
        self.app = wx.App()
        wx.Frame.__init__(self, None, -1, "Log in", size=(300,200))
        self.panel = wx.Panel(self)

        self.Show(True)
        self.Center(True)

    def __staticText(self):
        self.account_text = wx.StaticText(self.panel, -1, label="Account:", pos=(20,20))
        self.password_text = wx.StaticText(self.panel, -1, label="Password:", pos=(20,60))

    def __textCtrl(self):
        self.account_input = wx.TextCtrl(self.panel, -1, pos=(80,15), size=(180,25))
        self.password_input = wx.TextCtrl(self.panel, -1, pos=(90,55), size=(170,25), style=wx.TE_PASSWORD)

    def __button(self):
        self.logInButton = wx.Button(self.panel, -1, label="Log In", pos=(185,120))
        self.exitButton = wx.Button(self.panel, -1, label="Exit", pos=(90,120))

    def __sureEvent(self):
        pass

    def __eventHandler(self):
        pass

    def __password(self):
        with open("./login.js") as f:
            json.load(f)

    def __mainLoop(self):
        self.app.MainLoop()

    def start(self):
        self.__staticText()
        self.__textCtrl()
        self.__button()
        self.__mainLoop()




if __name__ == "__main__":
    program = loading()
    program.start()